Detailed description of the difference between Func and Action, funcaction
Differences between Func and Action
I. Func
Func is A. Net built-in delegate.
Func , Func is a. Net built-in generic delegate.
FuncFuncFuncFuncFunc
It has five forms, but
The difference between func and action is explained
First, Func
Func is a. NET built in delegate.
Func,func is a. NET-built generic delegate.
func
func
func
func
func
It has 5 forms, but the number of parameters is different; the
Delegation plays an extremely important role in C # programming. A delegate can encapsulate a function into a delegate object, and multiple delegates can be combined into one delegate, the delegate object can be stored and transferred like a normal
Delegation plays an extremely important role in C # programming. A delegate can encapsulate a function into a delegate object, and multiple delegates can be combined into one delegate, the delegate object can be stored and transferred like a normal
delegate, which occupies a very important place in C # programming, a delegate can encapsulate a function into a delegate object, and multiple delegates can be merged into a delegate, which can be stored, passed, and invoked as normal objects, so
delegate, which occupies a very important place in C # programming, a delegate can encapsulate a function into a delegate object, and multiple delegates can be merged into a delegate, which can be stored, passed, and invoked as normal objects, so
This is a creation in
Article, where the information may have evolved or changed.
Type TCPADDR//indicates TCP terminal address
Type tcpaddr struct { IP IP Port int //IPV6 addressing range }
Func resolvetcpaddr (NET, addr string)
Original http://www.cnblogs.com/skm-blog/archive/2013/05/24/3096294.html
Delegation plays an extremely important role in C # programming. A delegate can encapsulate a function into a delegate object, and multiple delegates can be combined into one
It's always been a bit confusing for events and delegates, and it's not going to work. Find a time, summed up a bit, feel a lot clearer.
Let's start with a personal understanding of the conclusion that:
delegate is a type in C # that is actually a
Func and action Delegate generics introductionAfter. Net 3.5, Microsoft introduced the func and action generic delegates. Further simplifies the definition of a delegate. The main manifestations of action are as follows: Public Delegate
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.